using System;

namespace BaddiesEditor
{
#if WINDOWS || XBOX
    /// <summary>
    /// Main program class.
    /// </summary>
    public static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        /// <param name="args">Arguments from the command line.</param>
        [STAThread]
        public static void Main(string[] args)
        {
            // Create and initialize game and form.
            EditorForm form = new EditorForm();
            form.Show();
            EditorGame game = new EditorGame(form.GetDrawSurface());
            MapProject mapProject = new MapProject();

            // Link game and form. Coupling for efficiency.
            form.Game = game;
            mapProject.Game = game;

            game.Form = form;
            mapProject.Form = form;

            form.MapProject = mapProject;
            game.MapProject = mapProject;

            form.ResizeGame();

            // Start xna game
            game.Run(); 
        }
    }
#endif
}

